Chapter 4 - Geometric Operations
This chapter describes the functions that allow you to perform geometric operations on shapes. Some of the geometric operations described in this chapter work on all types of shapes. Read this chapter if you perform any kind of geometric manipulation on the shapes you create.Before reading this chapter, you should be familiar with the QuickDraw GX object architecture as described in Inside Macintosh: QuickDraw GX Objects. You should also be familiar with the information in the chapters "Geometric Shapes" and "Geometric Styles" in this book.
For more information about geometric manipulation of shapes, you might want to read the chapter "Transform Objects" in Inside Macintosh: QuickDraw GX Objects and the chapter "QuickDraw GX Mathematics" in Inside Macintosh: QuickDraw GX Environment and Utilities.
This chapter introduces the basic categories of geometric operations and shows how to use these operations to
Finally, this chapter contains a complete reference for the geometric operations.
- determine and reverse the contour direction of a shape's contours
- simplify the geometric description of a shape
- incorporate style information into a shape's geometry
- obtain geometric information about a shape's geometry, such as contour length and area
- determine and alter the bounding rectangle of a shape
- inset a shape's geometry
- determine if two shapes touch
- determine if one shape contains another
- perform geometric arithmetic, such as intersection and union, on shapes
Chapter Contents
- About Geometric Operations
- Contours and Contour Direction
- Reducing and Simplifying Shape Geometries
- The Primitive Form of Shape Geometries
- Geometric Information
- Touching and Containing
- Geometric Arithmetic
- Using Geometric Operations
- Determining and Reversing Contour Direction
- Breaking Shape Contours
- Eliminating Unnecessary Geometric Points
- Simplifying Shapes
- Converting a Shape to Primitive Form
- Finding Geometric Information About a Shape
- Finding the Length of a Contour
- Finding the Point at a Certain Distance Along a Contour
- Finding the Bounding Rectangle and Center Point of a Shape
- Finding the Area of a Shape
- Setting a Shape's Bounding Rectangle
- Insetting Shapes
- Determining Whether Two Shapes Touch
- Determining Whether One Shape Contains Another
- Performing Geometric Arithmetic With Shapes
- Geometric Operations Reference
- Constants and Data Types
- Contour Directions
- Functions
- Determining and Reversing Contour Direction
- Breaking Shape Contours
- Reducing and Simplifying Shapes
- Incorporating Style Information Into Shape Geometries
- Finding Geometric Information About Shapes
- Getting and Setting Shape Bounds
- Insetting Shapes
- Determining Whether Two Areas Touch
- Determining Whether One Shape Contains Another
- Performing Geometric Arithmetic With Shapes
- Summary of Geometric Operations
- Constants and Data Types
- Contour Directions
- Functions
- Determining and Reversing Contour Direction
- Breaking Shape Contours
- Reducing and Simplifying Shapes
- Incorporating Style Information Into Shape Geometries
- Finding Geometric Information About Shapes
- Getting and Setting Shape Bounds
- Insetting Shapes
- Determining Whether Two Shapes Touch
- Determining Whether One Shape Contains Another
- Performing Geometric Arithmetic With Shapes
Main | Page One | What's New | Apple Computer, Inc. | Find It | Contact Us | Help